<!-- 第二行 -->

<template>
  <FormCheckbox :one="obj" :label="obj.targetName" bind="value" :dict="dict" :hasAll="false" @change="toChange">
    <!-- 标签 -->
    <template #label>
      <span>{{ obj.targetName }}</span>
      <el-tooltip :content="obj.describe" placement="right">
        <span class="inFlexCC">?</span>
      </el-tooltip>
    </template>
  </FormCheckbox>
</template>

<script>
// ============================== 导入依赖 ============================== //

import CORE from '@/CORE'
import Secure4 from '../../MySecure/Secure4'

// ============================== 导出组件 ============================== //

export default CORE.extend(Secure4, {
  /**
   * 名称定义 (实际使用名称)
   */
  name: 'Emergency2',

  /**
   * 计算属性 (慎用箭头函数)
   */
  computed: {
    /**
     * 对象
     */
    obj() {
      const matched = this.list.find((item) => item.targetItem === '30003002')
      return matched || {}
    },

    /**
     * 字典
     */
    dict() {
      return [
        ['1', '应急预案功能'],
        ['2', '应急预案编制'],
        ['3', '应急预案演练 (每半年)'],
        ['4', '应急预案评审'],
        ['5', '应急预案改进'],
      ]
    },
  },
})
</script>
